<!DOCTYPE html>
<html xmlns:th="http://www.w3.org/1999/xhtml">
<head th:replace="_fragments :: head(~{::title})" lang="en">
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width,initial-scale=1.0">
    <title>博客详情</title>
    <link rel="stylesheet" href="https://cdn.jsdelivr.net/semantic-ui/2.2.4/semantic.min.css" >
    <link rel="stylesheet" href="../static/css/me.css" >
    <link rel="stylesheet" href="../static/css/typo.css">
    <link rel="stylesheet" href="../static/css/animate.min.css">
    <link rel="stylesheet" href="../static/lib/prism/prism.css">
    <link rel="stylesheet" href="../static/lib/tocbot/tocbot.css">
    <link rel="stylesheet" href="../../static/lib/editormd/css/editormd.min.css">
    <script></script>
</head>
<body>
<!--导航-->
<nav th:replace="_fragments :: menu(1)"  class="ui inverted attached segment me-padded-tb-mini">
    <div class="ui container">
        <div class="ui menu inverted secondary stackable">
            <h2 class="ui teal header item ">Blog</h2>
            <a href="#" class="m-item item m-mobile-hide"><i class="home mini icon"></i>首页</a>
            <a href="#" class="m-item item m-mobile-hide"><i class="idea mini icon"></i>分类</a>
            <a href="#" class="m-item item m-mobile-hide"><i class="tags mini icon"></i>标签</a>
            <a href="#" class="m-item item m-mobile-hide"><i class="clone mini icon"></i>归档</a>
            <a href="#" class="m-item item m-mobile-hide"><i class="info mini icon"></i>关于我</a>
            <div class="right item m-mobile-hide">
                <div class="ui icon inverted transparent input">
                    <input type="text" placeholder="search..."/>
                    <i class="search link icon"></i>
                </div>
            </div>
        </div>
    </div>
    <a href="#" class="ui menu toggle button black icon m-top-right m-mobile-show">
        <i class="sidebar icon"></i>
    </a>
</nav>
<br>
<br>
<!--中间内容-->
<div id="waypoint" class="ui m-container-small m-container animated pulse">
    <div class="ui container">
        <div class="ui segment top attached">
            <div class="ui horizontal link list">
                <div class="item">
                    <img src="https://picsum.photos/id/0/100/100" alt=""
                         class="ui avatar image" th:src="@{${blog.user.avatar}}"/>
                    <div class="content"><a href="#" class="header" th:text="${blog.user.nickname}">奔跑的闲杠</a></div>
                </div>
                <div class="item">
                    <i class="calendar icon"></i><span th:text="${#dates.format(blog.updateTime,'yyyy-MM-dd')}">2018-10-10</span>
                </div>
                <div class="item">
                    <i class="eye icon"></i><span th:text="${blog.views}">2345</span>
                </div>
            </div>
        </div>
        <div class="ui attached segment">
            <!-- 图片区域-->
            <img src="https://picsum.photos/id/0/800/450" class="ui fluid image rounded " alt="" th:src="@{${blog.firstPicture}}"/>
        </div>
        <div class="ui attached segment padded">
            <!--内容-->
            <div class="ui right aligned basic segment">
                <div class="ui orange label basic" th:text="${blog.flag}">原创</div>
            </div>
            <h2 class="ui center aligned header" th:text="${blog.title}">
                物来顺应，未来不迎，当时不杂，即过不恋。
            </h2>
            <div id="content" class="typo typo-selection js-toc-content m-padded-lr-responsive m-padded-tb-large" th:utext="${blog.content}">
                <h1>中文网页重设与排版：<i class="serif">Typo.css</i></h1><br/>

                <h2 id="tagline" class="serif">一致化浏览器排版效果，构建最适合中文阅读的网页排版</h2>

                <ol id="table" class="ui table">
                    <li><a href="#section1">关于 <i class="serif">Typo.css</i></a></li>
                    <li><a href="#section2">排版实例</a>
                        <ul>
                            <li><a href="#section2-1">例1：论语学而篇第一</a></li>
                            <li><a href="#section2-2">例2：英文排版</a></li>
                        </ul>
                    </li>
                    <li><a href="#section3">附录</a>
                        <ul>
                            <li><a href="#appendix1"><i class="serif">Typo.css</i> 排版偏重点</a></li>
                            <li><a href="#appendix2">开源许可</a></li>
                        </ul>
                    </li>
                </ol>

                <h2 id="section1">一、关于 <i class="serif">Typo.css</i></h2>

                <p><i class="serif">Typo.css</i> 的目的是，在一致化浏览器排版效果的同时，构建最适合中文阅读的网页排版。</p>
                <h4>现状和如何去做：</h4>

                <p class="typo-first">排版是一个麻烦的问题 <sup><a href="#appendix1"># 附录一</a></sup>，需要精心设计，而这个设计却是常被视觉设计师所忽略的。前端工程师更常看到这样的问题，但不便变更。因为在多个 OS 中的不同浏览器渲染不同，改动需要多的时间做回归测试，所以改变变得更困难。而像我们一般使用的
                    Yahoo、Eric Meyer 和 Alice base.css 中采用的 Reset 都没有很好地考虑中文排版。<i class="serif">Typo.css</i> 要做的就是解决中文排版的问题。</p>

                <p><strong><i class="serif">Typo.css</i> 测试于如下平台：</strong></p>
                <table summary="Typo.css 的测试平台列表" class="ui table">
                    <thead>
                    <tr>
                        <th>OS/浏览器</th>
                        <th>Firefox</th>
                        <th>Chrome</th>
                        <th>Safari</th>
                        <th>Opera</th>
                        <th>IE9</th>
                        <th>IE8</th>
                        <th>IE7</th>
                        <th>IE6</th>
                    </tr>
                    </thead>
                    <tbody>
                    <tr>
                        <td>OS X</td>
                        <td>✔</td>
                        <td>✔</td>
                        <td>✔</td>
                        <td>✔</td>
                        <td>-</td>
                        <td>-</td>
                        <td>-</td>
                        <td>-</td>
                    </tr>
                    <tr>
                        <td>Win 7</td>
                        <td>✔</td>
                        <td>✔</td>
                        <td>✔</td>
                        <td>✔</td>
                        <td>✔</td>
                        <td>✔</td>
                        <td>✔</td>
                        <td>-</td>
                    </tr>
                    <tr>
                        <td>Win XP</td>
                        <td>✔</td>
                        <td>✔</td>
                        <td>✔</td>
                        <td>✔</td>
                        <td>-</td>
                        <td>✔</td>
                        <td>✔</td>
                        <td>✔</td>
                    </tr>
                    <tr>
                        <td>Ubuntu</td>
                        <td>✔</td>
                        <td>✔</td>
                        <td>-</td>
                        <td>✔</td>
                        <td>-</td>
                        <td>-</td>
                        <td>-</td>
                        <td>-</td>
                    </tr>
                    </tbody>
                </table>

                <h4>中文排版的重点和难点</h4>

                <p>在中文排版中，HTML4 的很多标准在语义在都有照顾到。但从视觉效果上，却很难利用单独的 CSS 来实现，像<abbr title="在文字下多加一个点">着重号</abbr>（例：这里<em class="typo-em">强调一下</em>）。在 HTML4 中，专名号标签（<code>&lt;u&gt;</code>）已经被放弃，而
                    HTML5 被<a href="http://html5doctor.com/u-element/">重新提起</a>。<i class="serif">Typo.css</i> 也根据实际情况提供相应的方案。我们重要要注意的两点是：</p>
                <ol>
                    <li>语义：语义对应的用法和样式是否与中文排版一致</li>
                    <li>表现：在各浏览器中的字体、大小和缩放是否如排版预期</li>
                </ol>
                <p>对于这些，<i class="serif">Typo.css</i> 排版项目的中文偏重注意点，都添加在附录中，详见：</p>
                <blockquote>
                    <b>附录一</b>：<a href="#appendix1"><i class="serif">Typo.css</i> 排版偏重点</a>
                </blockquote>

                <p>目前已有像百姓网等全面使用 <i class="serif">Typo.css</i> 的项目，测试平台的覆盖，特别是在<abbr title="手机、平板电脑等移动平台">移动端</abbr>上还没有覆盖完主流平台，希望有能力的同学能加入测试行列，或者加入到 <i class="serif">Typo.css</i>
                    的开发。加入方法：<a href="https://github.com/sofish/Typo.css">参与 <i class="serif">Typo.css</i> 开发</a>。如有批评、建议和意见，也随时欢迎给在 Github 直接提 <a
                            href="https://github.com/sofish/Typo.css/issues">issues</a>，或给<abbr title="Sofish Lin, author of Typo.css"
                                                                                                role="author">我</abbr>发<a
                            href="mailto:sofish@icloud.com">邮件</a>。</p>


                <h2 id="section2">二、排版实例：</h2>

                <p>提供2个排版实例，第一个中文实例来自于来自于<cite class="typo-unique">张燕婴</cite>的《论语》，由于古文排版涉及到的元素比较多，所以采用《论语》中《学而》的第一篇作为排版实例介绍；第2个来自到经典的
                    Lorem Ipsum，并加入了一些代码和列表等比较具有代表性的排版元素。</p>

                <h3 id="section2-1">例1：论语学而篇第一</h3>

                <p>
                    <small><b>作者：</b><abbr title="名丘，字仲尼">孔子</abbr>（
                        <time>前551年9月28日－前479年4月11日</time>
                        ）
                    </small>
                </p>

                <h4>本篇引语</h4>

                <p>
                    《学而》是《论语》第一篇的篇名。《论语》中各篇一般都是以第一章的前二三个字作为该篇的篇名。《学而》一篇包括16章，内容涉及诸多方面。其中重点是「吾日三省吾身」；「节用而爱人，使民以时」；「礼之用，和为贵」以及仁、孝、信等道德范畴。 </p>

                <h4>原文</h4>

                <p>子曰：「学而时习之，不亦说乎？有朋自远方来，不亦乐乎？人不知，而不愠，不亦君子乎？」 </p>

                <h4>译文</h4>

                <p>孔子说：「学了又时常温习和练习，不是很愉快吗？有志同道合的人从远方来，不是很令人高兴的吗？人家不了解我，我也不怨恨、恼怒，不也是一个有德的君子吗？」 </p>

                <h4>评析</h4>


                    <tr>
                        <td colspan="3">（5）默认字体色彩，目前采用 <code>#333</code> 在各种浏览显示比较好</td>
                    </tr>
                    </tbody>
                </table>

                <h5 id="appendix2">2、开源许可</h5>

                <p><i class="serif">Typo.css</i> 基于 <a href="http://zh.wikipedia.org/wiki/MIT_License">MIT License</a> 开源，使用代码只需说明来源，或者引用 <a
                        href="http://typo.sofi.sh/license.txt">license.txt</a> 即可。</p>
            </div>
            <!-- 标签-->
            <div class="ui m-padded-lr-responsive m-padded-tb-large">
                <div class="ui basic teal left pointing label" th:each="tag:${blog.tags}" th:text="${tag.name}">方法论</div>
            </div>
            <!-- 赞赏功能-->
            <div class="ui center aligned basic segment" th:if="${blog.appreciation}">
                <button id="payButton" class="ui orange basic circular button">赞赏</button>
            </div>
            <div class="ui payQR flowing popup transition hidden">
                <div class="ui orange basic label">
                    <div class="ui images" style="font-size: inherit !important;">
                        <div class="image">
                            <img src="../static/images/wechat.jpg" th:src="@{/images/wechat.jpg}" alt="" class="ui image rounded bordered" style="width: 120px"/>
                            <div>微信</div>
                        </div>
                        <div class="image">
                            <img src="../static/images/wechat.jpg" alt="" th:src="@{/images/wechat.jpg}" class="ui image rounded bordered" style="width: 120px"/>
                            <div>支付宝</div>
                        </div>
                    </div>
                </div>
            </div>
        </div>
        <div class="ui attached positive  message" th:if="${blog.shareStatement}">
            <!--博客信息-->
            <div class="ui grid middle aligned">
                <div class="eleven wide column">
                    <ul class="list">
                        <li>作者: <span th:text="${blog.user.nickname}">奔跑的闲杠</span> <a href="#" th:href="@{/about}" target="_blank">(联系作者)</a></li>
                        <li>发表时间: <span th:text="${#dates.format(blog.updateTime,'yyyy-MM-dd HH:mm')}">2018-10-10</span></li>
                        <li>版权申明:自由转载-非商用-非衍生-保持署名</li>
                        <li>公众转载:请在文末添加作者公众号二维码</li>
                    </ul>
                </div>
                <div class="five wide column">
                    <img src="../static/images/wechat.jpg" alt="" th:src="@{/images/wechat.jpg}" class="ui right floated bordered rounded image" style="width: 110px"/>
                </div>
            </div>
        </div>
        <div  class="ui bottom attached segment" th:if="${blog.commentabled}">
            <!--留言区域-->
            <div id="comment-container" class="ui violet segment">
               <div th:fragment="commentList">
                <div class="ui  threaded  comments" style="max-width: 100%;">
                    <h3 class="ui  dividing header">评论</h3>
                        <div class="comment" th:each="comment:${comments}">
                            <a class="avatar">
                                <img src="https://picsum.photos/id/0/100/100" th:src="@{${comment.avatar}}">
                            </a>
                            <div class="content">
                                <a class="author">
                                    <span th:text="${comment.nickname}">Matt</span>
                                    <div class="ui mini basic teal left pointing label m-padded-mini" th:if="${comment.adminComment}">博主</div>
                                </a>
                                <div class="metadata">
                                    <span class="date" th:text="${#dates.format(comment.createTime,'yyyy-MM-dd HH:mm')}">Today at 5:42PM</span>
                                </div>
                                <div class="text" th:text="${comment.content}">
                                    How artistic!
                                </div>
                                <div class="actions">
                                    <a class="reply" data-commentid="1" data-commentnickname="Matt" th:attr="data-commentid=${comment.id},data-commentnickname=${comment.nickname}" onclick="reply(this)">回复</a>
                                </div>
                            </div>

                            <div class="comments" th:if="${#arrays.length(comment.replyComments)}>0">
                                <div class="comment" th:each="reply:${comment.replyComments}">
                                    <a class="avatar">
                                        <img src="https://picsum.photos/id/0/100/100" th:src="@{${reply.avatar}}">
                                    </a>
                                    <div class="content">
                                        <a class="author">
                                            <span th:text="${reply.nickname}">Matt</span>
                                            <span th:text="|@ ${reply.parentComment.nickname}|" class="m-teal">@小白</span>
                                            <div class="ui mini basic teal left pointing label m-padded-mini" th:if="${reply.adminComment}">博主</div>
                                        </a>
                                        <div class="metadata">
                                            <span class="date" th:text="${#dates.format(reply.createTime,'yyyy-MM-dd HH:mm')}">Today at 5:42PM</span>
                                        </div>
                                        <div class="text" th:text="${reply.content}">
                                            How artistic!
                                        </div>
                                        <div class="actions">
                                            <a class="reply" data-commentid="1" data-commentnickname="Matt" th:attr="data-commentid=${reply.id},data-commentnickname=${reply.nickname}" onclick="reply(this)">回复</a>
                                        </div>
                                    </div>
                                </div>
                            </div>
                        </div>

                    </div>
                    <!--/*-->
                    <div class="comment">
                        <a class="avatar">
                            <img src="https://picsum.photos/id/0/100/100">
                        </a>
                        <div class="content">
                            <a class="author">Elliot Fu</a>
                            <div class="metadata">
                                <span class="date">Yesterday at 12:30AM</span>
                            </div>
                            <div class="text">
                                <p>This has been very useful for my research. Thanks as well!</p>
                            </div>
                            <div class="actions">
                                <a class="reply">回复</a>
                            </div>
                        </div>
                        <div class="comments">
                            <div class="comment">
                                <a class="avatar">
                                    <img src="https://picsum.photos/id/0/100/100">
                                </a>
                                <div class="content">
                                    <a class="author">Jenny Hess</a>
                                    <div class="metadata">
                                        <span class="date">Just now</span>
                                    </div>
                                    <div class="text">
                                        Elliot you are always so right :)
                                    </div>
                                    <div class="actions">
                                        <a class="reply">回复</a>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                    <div class="comment">
                        <a class="avatar">
                            <img src="https://picsum.photos/id/0/100/100">
                        </a>
                        <div class="content">
                            <a class="author">Joe Henderson</a>
                            <div class="metadata">
                                <span class="date">5 days ago</span>
                            </div>
                            <div class="text">
                                Dude, this is awesome. Thanks so much
                            </div>
                            <div class="actions">
                                <a class="reply">回复</a>
                            </div>
                        </div>
                    </div>
                    <!--*/-->
                </div>
            </div>
            <div id="commend-form" class="ui form">
                <input type="hidden" name="blog.id" th:value="${blog.id}">
                <input type="hidden" name="parentComment.id" th:value="-1">
                <div class="field">
                    <textarea name="content" id="" cols="30" rows="10" placeholder="请输入评论信息..."></textarea>
                </div>
                <div class="fields">
                    <div class="field m-mobile-wide m-margin-bottom-mini">
                        <div class="ui left icon input">
                            <i class="user icon"></i>
                            <input type="text" name="nickname" placeholder="姓名" th:value="${session.user}!=null ? ${session.user.nickname}"/>
                        </div>
                    </div>
                    <div class="field m-mobile-wide m-margin-bottom-mini">
                        <div class="ui left icon input">
                            <i class="mail icon"></i>
                            <input type="email" placeholder="邮箱" name="email" th:value="${session.user}!=null ? ${session.user.email}"/>
                        </div>
                    </div>
                    <div class="field  m-margin-bottom-mini m-mobile-wide">
                        <button id="commentpost-btn" class="ui teal button m-mobile-wide"><i class="edit icon"></i>发布评论</button>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>
<br>
<br>
<div id="toolbar" class="m-padded  m-fixed m-right-bottom" style="display: none;">
<div class="ui vertical icon buttons">
    <button class="ui teal button toc" type="button">目录</button>
    <a href="#comment-container" class="ui teal button">留言</a>
    <button class="ui wechat icon button"><i class="weixin icon"></i></button>
    <!--<a href="#" class="ui icon button"><i class="chevron up icon"></i></a>-->
    <div id="toTop-button" class="ui icon button"><i class="chevron up icon"></i></div>
</div>
</div>
<div class="ui toc-container flowing popup transition hidden" style="width: 250px !important;">
    <ol class="js-toc">

    </ol>
</div>
<div id="qrcode" class="ui wechat-qr flowing popup transition hidden" style="width: 120px !important;">
    <!--<img src="./static/images/wechat.jpg" alt="" class="ui rounded image" style="width: 110px">-->
</div>
<!--底部-->
<footer th:replace="_fragments :: footer" class="ui inverted vertical segment m-padded-tb-massive">
    <div class="ui center aligned container">
        <div class="ui inverted divided stackable grid">
            <div class="three wide column">
                <div class="ui inverted link list">
                    <div class="item">
                        <img src="../static/images/wechat.jpg" th:src="@{/images/wechat.jpg}"  class="ui rounded image" alt="" style="width: 110px">
                    </div>
                </div>
            </div>
            <div class="three wide column" >
                <h4 class="ui inverted header m-text-thin m-text-spaced " >最新博客</h4>
                <div id="newblog-container">
                    <div class="ui inverted link list" th:fragment="newblogList">
                        <a href="#" th:href="@{/blog/{id}(id=${blog.id})}" target="_blank" class="item m-text-thin" th:each="blog : ${newblogs}" th:text="${blog.title}">用户故事（User Story）</a>
                        <!--/*-->
                        <a href="#" class="item m-text-thin">用户故事（User Story）</a>
                        <a href="#" class="item m-text-thin">用户故事（User Story）</a>
                        <!--*/-->
                    </div>
                </div>
            </div>
            <div class="three wide column">
                <h4 class="ui inverted header m-text-thin m-text-spaced ">联系我</h4>
                <div class="ui inverted link list">
                    <a href="#" class="item m-text-thin" th:text="#{index.email}">Email：lirenmi@163.com</a>
                    <a href="#" class="item m-text-thin" th:text="#{index.qq}">QQ：865729312</a>
                </div>
            </div>
            <div class="seven wide column">
                <h4 class="ui inverted header m-text-thin m-text-spaced ">Blog</h4>
                <p class="m-text-thin m-text-spaced m-opacity-mini" th:text="#{index.blogDescription}">测试</p>
            </div>
        </div>
        <div class="ui inverted section divider"></div>
        <p class="m-text-thin m-text-spaced m-opacity-tiny">Copyright © 2016 - <span th:text="${#dates.year(#dates.createNow())}">2017</span> Lirenmi Designed by Lirenmi</p>
    </div>
</footer>
<!--/*/<th:block th:replace="_fragments :: script">/*/-->
<script src="https://cdn.jsdelivr.net/npm/jquery@3.2/dist/jquery.min.js"></script>
<script src="https://cdn.jsdelivr.net/semantic-ui/2.2.4/semantic.min.js"></script>
<script src="//cdn.jsdelivr.net/npm/jquery.scrollto@2.1.2/jquery.scrollTo.min.js"></script>

<script src="../static/lib/prism/prism.js"></script>
<script src="../static/lib/tocbot/tocbot.min.js"></script>
<script src="../static/lib/qrcode/qrcode.min.js"></script>
<script src="../static/lib/waypoints/jquery.waypoints.min.js"></script>
<!--/*/</th:block>/*/-->
<script th:inline="javascript">
    <!--添加inline模板取值才生效-->
    $('.menu.toggle').click(function(){
        $('.m-item').toggleClass('m-mobile-hide');
    });
    $('#payButton').popup({
        popup:$('.payQR.popup'),
        on :'click',
        position :'bottom center'
    });
    tocbot.init({
        // Where to render the table of contents.
        tocSelector: '.js-toc',
        // Where to grab the headings to build the table of contents.
        contentSelector: '.js-toc-content',
        // Which headings to grab inside of the contentSelector element.
        headingSelector: 'h1, h2, h3',
        // For headings inside relative or absolute positioned containers within content.
//        hasInnerContainers: true,
    });
    $('.toc.button').popup({
        popup:$('.toc-container.popup'),
        on :'click',
        position :'left center',
    });
    $('.wechat').popup({
        popup : $('.wechat-qr'),
        position: 'left center'
    });
    var serurl="127.0.0.1:8080";
    var url= /*[[@{/blog/{id}(id=${blog.id})}]]*/"";
    var qrcode = new QRCode(document.getElementById("qrcode"), {
        // text: "http://jindo.dev.naver.com/collie",
        text:serurl+url,
        width: 110,
        height: 110,
        colorDark : "#000000",
        colorLight : "#ffffff",
        correctLevel : QRCode.CorrectLevel.H
    });
    $('#toTop-button').click(function(){
        $(window).scrollTo(0,1000)
    });
    var waypoint = new Waypoint({
        element: document.getElementById('waypoint'),
        handler: function(direction) {
//            console.log('Scrolled to waypoint!')
            if(direction=='down'){
                $('#toolbar').show(500);
            }else{
                $('#toolbar').hide(500);
            }
        }
    })

    //评论表单验证
    $('.ui.form').form({
        fields: {
            title: {
                identifier: 'content',
                rules: [{
                    type: 'empty',
                    prompt: '请输入评论内容'
                }
                ]
            },
            content: {
                identifier: 'nickname',
                rules: [{
                    type: 'empty',
                    prompt: '请输入你的大名'
                }]
            },
            type: {
                identifier: 'email',
                rules: [{
                    type: 'email',
                    prompt: '请填写正确的邮箱地址'
                }]
            }
        }
    });
    $(function () {
        $("#comment-container").load(/*[[@{/comments/{id}(id=${blog.id})}]]*/"comments/6");
    });
    $('#commentpost-btn').click(function () {
        var boo=$('.ui.form').form('validate form');
        if(boo){
            console.log("晓燕成功");
            postData();
        }else {
            console.log("校验失败");
        }
    });
    function postData() {
        $("#comment-container").load(/*[[@{/comments}]]*/"", {
            "parentComment.id": $("[name='parentComment.id']").val(),
            "blog.id": $("[name='blog.id']").val(),
            "nickname": $("[name='nickname']").val(),
            "email": $("[name='email']").val(),
            "content": $("[name='content']").val()
        }, function (responseTxt, statusTxt, xhr) {
       $(window).scrollTo($('#comment-container'),500);
            clearContent();
        });
    }
    function clearContent() {
        $("[name='content']").val('');
        $("[name='parentComment.id']").val(-1);
        $("[name='content']").attr("placeholder", "请输入评论信息...");
    }
    function reply(obj) {
        var commentId=$(obj).data('commentid');
        var commentNickname=$(obj).data("commentnickname");
        $("[name='content']").attr("placeholder", "@"+commentNickname).focus();
        $("[name='parentComment.id']").val(commentId);
        $(window).scrollTo($('#comment-form'),500);
    }
</script>
</body>
</html>